package com.ruanda.feign;


import com.ruanda.domain.MemberAddr;
import com.ruanda.feign.sentinel.OrderMemberSentinel;
import com.ruanda.model.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(value = "member-service",fallback = OrderMemberSentinel.class)
public interface OrderMemberFeign {
    
    @GetMapping("p/address/getMemberAddrById")
    public Result<MemberAddr> getMemberAddrById(@RequestParam Long addrId);
    
    @GetMapping("p/address/getMemberDefaultAddrByOpenId")
    public Result<MemberAddr> getMemberDefaultAddrByOpenId(@RequestParam String openId);

    @GetMapping("admin/user/getNickNameByOpenId")
    public Result<String> getNickNameByOpenId(@RequestParam String openId);
}
